package host.springboot.framework.core.logging;

import host.springboot.framework.core.model.Pair;
import lombok.AllArgsConstructor;
import org.jspecify.annotations.NonNull;
import org.jspecify.annotations.Nullable;
import org.slf4j.Logger;
import org.slf4j.event.Level;

import java.util.List;

/**
 * 日志组件实现
 *
 * @author JiYinchuan
 * @since 1.0.0
 */
@AllArgsConstructor
public class LoggingComponentImpl implements LoggingComponent, LogComponentProvider {

    /**
     * 日志组件
     */
    private final LoggingComponent component;

    @Override
    public @NonNull Logger log() {
        return component.log();
    }

    @Override
    public @NonNull String logTag() {
        return component.logTag();
    }

    @Override
    public @NonNull String log(
            @NonNull Logger logger,
            @NonNull Level level,
            @NonNull String logTag,
            @NonNull String logDetailTag,
            @Nullable Throwable throwable,
            @Nullable List<@NonNull Pair<@Nullable String, @Nullable Object>> additionalMessages) {
        return "";
    }
}
